package com.gzsxy.excel.constants;

/**
 * @Author
 * @Description
 * @Date 2022/01/19
 * @Param $
 * @return $
 **/
public class productConstants {
    public enum stateEu{

        /**
         * Not started
         */
        NOSTART("未启动","1"),
        /**
         * Under development
         */
        UNDER("研发中","2"),
        /**
         *  STOP
         */
        STOP("暂停","3"),
        /**
         * In testing
         */
        INTEST("提测中","4"),
        /**
         * Archived
         */
        ARCHIVED("已归档","5");


        private String value;
        private String name;
        stateEu(String name,String value) {
            this.value = value;
            this.name = name;
        }

        public static String getNameByValue(String value) {
            for (stateEu t : stateEu.values()) {
                if (t.getValue().equals(value)) {
                    return t.getName();
                }
            }
            return null;
        }

        public static String getValueByName(String name) {
            for (stateEu t : stateEu.values()) {
                if (t.getName().equals(name)) {
                    return t.getValue();
                }
            }
            return null;
        }

        public String getValue() {
            return this.value;
        }

        public String getName() {
            return this.name;
        }
    }

    public enum delayEu{

        /**
         * Not started
         */
        YES("是","1"),
        NO("否","0");
        private String value;
        private String name;
        delayEu(String name,String value) {
            this.value = value;
            this.name = name;
        }

        public static String getNameByValue(String value) {
            for (delayEu t : delayEu.values()) {
                if (t.getValue().equals(value)) {
                    return t.getName();
                }
            }
            return null;
        }

        public static String getValueByName(String name) {
            for (delayEu t : delayEu.values()) {
                if (t.getName().equals(name)) {
                    return t.getValue();
                }
            }
            return null;
        }

        public String getValue() {
            return this.value;
        }

        public String getName() {
            return this.name;
        }
    }
}
